<template>
<!-- 顶部通栏 -->
  <app-topnav></app-topnav>
  <!-- 头部 -->
  <app-header></app-header>
  <!-- 2.2 固定头部布局-->
 <AppHeaderSticky />
  <!-- 中间内容 -->
  <main>
    <!-- 二级路由 -->
    <RouterView></RouterView>
  </main>
  <!-- 底部 -->
  <app-footer></app-footer>
</template>

<script>
import appTopnav from '@/components/app-topnav.vue'
import AppHeader from '@/components/app-header.vue'
import AppFooter from '@/components/app-footer.vue'
import AppHeaderSticky from '@/components/app-header-sticky.vue'
import { useStore } from 'vuex'
export default {
  components: { appTopnav, AppHeader, AppFooter, AppHeaderSticky },
  name: 'xtx-layout',
  setup () {
    const store = useStore()
    store.dispatch('category/findList')
  }
}
</script>

<style scoped lang="less"></style>
